<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>店铺详情</title>
    <!-- 引入vue和axios -->
    <script src="js/plugins/vue/dist/vue.js"></script>
    <script src="js/plugins/axios/dist/axios.js"></script>
    <!-- axios全局配置 -->
    <script src="js/common.js"></script>
</head>
<body>
<div id="myApp">
    <span style="font-size: 30px">{{shop.name}}</span>
</div>
</body>
<script type="text/javascript">
    new Vue({
        el: "#myApp",
        data: {
            shop:{}
        },
        mounted(){
            let id = parseUrlParams2Obj(location.href).id;
            this.$http.get("/shop/"+id).then(res => {
                this.shop = res.data;
            }).catch(res => {
                alert("系统错误");
            })

        }
    });
</script>
</html>